<template>
<div id="box">
  <ul><span> <el-link icon="el-icon-user" disabled="true" underline="underline" style="color: goldenrod">{{username}}</el-link>&nbsp;
    <el-link icon="el-icon-setting" style="color: aliceblue" :underline="false" v-on:click="Infocheck">个人信息</el-link>&nbsp;
    <el-link icon="el-icon-warning" href="/" style="color:aliceblue" :underline="false">退出登录</el-link>
  </span>

  </ul>
</div>
</template>

<script>
import Home from "../views/Home";

export default {
  name: "userItem",

  data() {
    return {
      username:JSON.parse(sessionStorage.getItem("user")).name,
    }
  },

  methods:{
    Infocheck:function(){
      window.open('/Info','_self');
    },
  },
}
</script>

<style scoped>
  #box{
    size: auto;
    background-color: #2c3e50;
    color: aliceblue;
    text-align: right;
    padding: 10px;
    flex: border-box;
  }
</style>